package com.lyl.security.dto;

import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;

/**
 * @author Mr.Luo
 * @date 2022-09-19 11:43
 * @desc
 */
@Data
public class UserDTO {

    @NotBlank(message = "用户名不能为空")
    @Length(min = 1, max = 20, message = "用户名长度在1到20之间")
    private String username;

    @NotBlank(message = "密码不能为空")
    @Length(min = 3, max = 20, message = "密码长度在6到20之间")
    private String password;
}
